package cc.eddic.practice.spring.dto;

import cc.eddic.practice.spring.domain.Category;
import cc.eddic.practice.spring.domain.SubCategory;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
@AllArgsConstructor
public class SubCategoryAddRequest {
    private String name;
    private Category category;
    public SubCategory as() {
        return new SubCategory(this.name,this.category);
    }
}
